<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Snake: C:/Documents and Settings/HP_Omistaja/Työpöytä/windowsPeli/winPeliSVN/winPeli/snake.h lähdekooditiedosto</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript">
$(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generoinut Doxygen 1.7.4 -->
<div id="top">
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">Snake</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Pääsivu</span></a></li>
      <li><a href="namespaces.html"><span>Nimiavaruudet</span></a></li>
      <li><a href="annotated.html"><span>Luokat</span></a></li>
      <li class="current"><a href="files.html"><span>Tiedostot</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>Tiedostolista</span></a></li>
      <li><a href="globals.html"><span>Tiedoston&#160;jäsenet</span></a></li>
    </ul>
  </div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('snake_8h.html','');
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">C:/Documents and Settings/HP_Omistaja/Työpöytä/windowsPeli/winPeliSVN/winPeli/snake.h</div>  </div>
</div>
<div class="contents">
<a href="snake_8h.html">Siirry tämän tiedoston dokumentaatioon.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 
<a name="l00008"></a>00008 <span class="preprocessor">#ifndef SNAKE_H</span>
<a name="l00009"></a>00009 <span class="preprocessor"></span><span class="preprocessor">#define SNAKE_H</span>
<a name="l00010"></a>00010 <span class="preprocessor"></span>
<a name="l00011"></a>00011 <span class="preprocessor">#include &lt;windows.h&gt;</span>
<a name="l00012"></a>00012 <span class="preprocessor">#include &quot;<a class="code" href="block_8h.html">block.h</a>&quot;</span>
<a name="l00013"></a>00013 
<a name="l00014"></a><a class="code" href="class_snake.html">00014</a> <span class="keyword">class </span><a class="code" href="class_snake.html">Snake</a>
<a name="l00015"></a>00015 {
<a name="l00016"></a>00016 <span class="keyword">public</span>:
<a name="l00022"></a>00022         <a class="code" href="class_snake.html#a32b3531dd5974b8d157fcbb84b490e52">Snake</a>(<span class="keywordtype">int</span> x, <span class="keywordtype">int</span> y);
<a name="l00023"></a>00023     
<a name="l00027"></a>00027         <a class="code" href="class_snake.html#a941fbaad96ee33ca3a7c30c28ca44ef8">~Snake</a>();
<a name="l00028"></a>00028     
<a name="l00034"></a>00034         <span class="keywordtype">void</span> <a class="code" href="class_snake.html#a70633b60e38c1b03358e9292a32fa3c7">move</a>(<span class="keywordtype">int</span> x, <span class="keywordtype">int</span> y);
<a name="l00035"></a>00035     
<a name="l00041"></a>00041         <span class="keywordtype">bool</span> <a class="code" href="class_snake.html#a8251b1fc68c632af86eef620256aec1f">collision</a>(<a class="code" href="class_block.html">Block</a>* block);
<a name="l00042"></a>00042     
<a name="l00046"></a>00046         <span class="keywordtype">void</span> <a class="code" href="class_snake.html#a24aeabf4615c0d8d91edf95ecfbd5c60">addLength</a>();
<a name="l00047"></a>00047     
<a name="l00056"></a>00056         <span class="keywordtype">bool</span> <a class="code" href="class_snake.html#af79498343f5f511cfb86dbe7048a1f85">outsideRectangle</a>(<span class="keywordtype">int</span> x1, <span class="keywordtype">int</span> y1, <span class="keywordtype">int</span> x2, <span class="keywordtype">int</span> y2);
<a name="l00057"></a>00057     
<a name="l00062"></a>00062         <span class="keywordtype">bool</span> <a class="code" href="class_snake.html#ab1814935ff835fbe3ce11de75012db8a">collisionWithItself</a>();
<a name="l00063"></a>00063     
<a name="l00068"></a>00068         <span class="keywordtype">int</span> <a class="code" href="class_snake.html#a7aee0ab8b45446d0736423b51fd077da">getX</a>();
<a name="l00069"></a>00069     
<a name="l00074"></a>00074         <span class="keywordtype">int</span> <a class="code" href="class_snake.html#aa7bb36db425d5588349de8a8d5b278cf">getY</a>();
<a name="l00075"></a>00075     
<a name="l00080"></a>00080         <span class="keywordtype">void</span> <a class="code" href="class_snake.html#aa34f490538ed582a33c9aded6c226a7f">setDirection</a>(<span class="keywordtype">int</span> dir);
<a name="l00081"></a>00081     
<a name="l00086"></a>00086         <span class="keywordtype">int</span> <a class="code" href="class_snake.html#af6d4987dc204b4f9612dd3431d2cb0f2">getDirection</a>();
<a name="l00087"></a>00087     
<a name="l00094"></a>00094         <span class="keywordtype">void</span> <a class="code" href="class_snake.html#adac9182b065f945a8ea1114a3d03e284">draw</a>(HDC hdc, <span class="keywordtype">int</span> x, <span class="keywordtype">int</span> y);
<a name="l00095"></a>00095 
<a name="l00096"></a>00096 <span class="keyword">private</span>:
<a name="l00097"></a><a class="code" href="class_snake.html#a1349ccf7f145382b601ac41927f84af4">00097</a>         <span class="keywordtype">int</span> <a class="code" href="class_snake.html#a1349ccf7f145382b601ac41927f84af4">direction</a>;
<a name="l00098"></a><a class="code" href="class_snake.html#aba2f9d9cbf10b4be4887e5bc9612bfde">00098</a>         <span class="keywordtype">int</span> <a class="code" href="class_snake.html#aba2f9d9cbf10b4be4887e5bc9612bfde">length</a>;
<a name="l00099"></a><a class="code" href="class_snake.html#a9b1b4e890de54b0fe8fdff0e9f641612">00099</a>         <a class="code" href="class_block.html">Block</a>* <a class="code" href="class_snake.html#a9b1b4e890de54b0fe8fdff0e9f641612">blocks</a>[100];
<a name="l00100"></a>00100 };
<a name="l00101"></a>00101 
<a name="l00102"></a>00102 <span class="preprocessor">#endif</span>
</pre></div></div>
</div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="snake_8h.html">snake.h</a>      </li>
      <li class="footer">Generoinut projektille Snake Sat Apr 16 2011 19:06:20 &#160;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.4 </li>
    </ul>
  </div>

</body>
</html>
